def create_elbowRF
    model = Sketchup.active_model
    prompts = ["直段长度","弯头长度","直径"]
        defaults = ["3000","150","25"]
        input = UI.inputbox(prompts, defaults, "创建一头弯钢筋")
    group = model.active_entities.add_group
        entities = group.entities
    
    x = input[0].to_f.mm
    y = input[1].to_f.mm
    dia = input[2].to_f.mm
    
        points = [
            Geom::Point3d.new(0,  dia/2, 0),
            Geom::Point3d.new(x-dia*3, dia/2,  0),
            Geom::Point3d.new(x-dia/2, dia*3,   0),
            Geom::Point3d.new(x-dia/2, y,   0)
        ]
    
    edges = entities.add_line points[0],points[1]
    edges = entities.add_line points[2],points[3]
    
    cpoint = Geom::Point3d.new(x-dia*3, dia*3,   0)
    vector = Geom::Vector3d.new 0,0,1
    vector2 = Geom::Vector3d.new 1,0,0
    vector3 = vector.normalize!
    entities.add_arc cpoint, vector2, vector3, 2.5*dia, 270.degrees, 360.degrees
    
    vector = Geom::Vector3d.new 1,0,0
    vector2 = vector.normalize!
    face = entities.add_face(entities.add_circle points[0], vector2, dia/2)
    face.followme(edges.all_connected)

end
